package com.ruoyi.web.controller.workflow;

import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.workflow.domain.CarPackageAudit;
import com.ruoyi.workflow.service.ICarPackageAuditService;
import com.ruoyi.workflow.service.ITodoTaskService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 套餐审核Controller
 *
 * @author xiaoliu
 * @date 2022-11-17
 */
@RestController
@RequestMapping("/workflow/done")
public class DoneTaskController extends BaseController {
    @Autowired
    private ICarPackageAuditService carPackageAuditService;

    /**
     * 我的已办
     *
     * @param carPackageAudit
     * @return
     */
    @GetMapping
    public TableDataInfo done(CarPackageAudit carPackageAudit) {
        return carPackageAuditService.done(carPackageAudit);
    }

    @GetMapping("/historyList")
    public AjaxResult done(String instanceId) {
        return AjaxResult.success(carPackageAuditService.historyList(instanceId));
    }


}
